<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>金字塔</title>
		<style type="text/css">
			div{
				width: 300px;
				height: 300px;
				margin: 0px auto;
			}
		</style>
		
	</head>
	<body>
		<div id="">
			<script type="text/javascript">
			document.write("<h1>打印倒金字塔直线</h1> ");
			var h=prompt("输入高度","");
			for (var i=h-1;i>0;i--) {
				document.write("<hr width="+(i*50+10)+"px;/>");
			}
			for (var j=0;j<h;j++) {
				document.write("<hr width="+(j*50+10)+"px;/>");
			}
		</script>
		<a style="width: 20;"></a>
		</div>
		
	</body>
</html>
